package cn.gson.boot.model.mapper;

import cn.gson.boot.model.pojos.Competitor;
import cn.gson.boot.model.pojos.ContendStatus;
import cn.gson.boot.model.pojos.Kehu;
import cn.gson.boot.model.pojos.Sales;
import org.springframework.data.repository.query.Param;
import org.springframework.stereotype.Repository;

import java.util.List;


@Repository
public interface CompetitorMapper {

    //竞争对手分页查询
    public List<Competitor> selectCompetitors(@Param("search") String search,
                                              @Param("type") String type,
                                              @Param("empName") String empName);

    //查询需要修改的竞争对手
    List<Competitor> upCompetitor(@Param("competitorId") Integer competitorId);

    //客户列表
    List<Kehu> selectKh(@Param("khsearch") String khsearch,
                        @Param("empName") String empName);


    //对应机会列表
    List<Sales> selectSales(@Param("khName") String khName);

    //查询竞争状态列表
    public List<ContendStatus> conList();

    //销售机会页面已生成竞争对手不可删除
    List<Competitor> selectSalesCompetitor(Integer salesId);
}
